<!doctype html>
<html class="no-js">
<head>
  <meta charset="utf-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <title>商之联运营商后台</title>
  <meta name="description" content="这是一个form页面">
  <meta name="keywords" content="form">
  <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
  <meta name="renderer" content="webkit">
  <meta http-equiv="Cache-Control" content="no-siteapp" />
  <link rel="icon" type="image/png" href="{:C('SUPPLIER_ADMIN_IMAGE')}favicon.png"> <link rel="apple-touch-icon-precomposed" href="{:C('SUPPLIER_ADMIN_IMAGE')}app-icon72x72@2x.png">
  <meta name="apple-mobile-web-app-title" content="Amaze UI" />
  <link rel="stylesheet" href="{:C('SUPPLIER_ADMIN_CSS')}amazeui.min.css"/>
  <link rel="stylesheet" href="{:C('SUPPLIER_ADMIN_CSS')}admin.css">
</head>
<body>
<!--[if lte IE 9]>
<p class="browsehappy">你正在使用<strong>过时</strong>的浏览器，Amaze UI 暂不支持。 请 <a href="http://browsehappy.com/" target="_blank">升级浏览器</a>
  以获得更好的体验！</p>
<![endif]-->
<!-- header start-->

<include file="Public:header"/>

<!-- header end-->

<div class="am-cf admin-main">
  <!-- sidebar start -->
     <include file="Public:menu"/>
  <!-- sidebar end -->

<!-- content start -->
<div class="admin-content">

  <div class="am-cf am-padding">
    <div class="am-fl am-cf"><strong class="am-text-primary am-text-lg">加盟商管理</strong> / <small>添加加盟商</small></div>
  </div>

  <div class="am-tabs am-margin" data-am-tabs>
    <ul class="am-tabs-nav am-nav am-nav-tabs">
      <li class="am-active"><a href="#tab1">企业基本信息</a></li>
      <li><a href="#tab2">绑定用户</a></li>
    </ul>
    <form action="{:U('ShopManage/saveShop')}" method="post" id="shop">
    <div class="am-tabs-bd">
      <div class="am-tab-panel am-fade am-in am-active" id="tab1">
            
            <div class="am-g am-margin-top">
            <div class="am-u-sm-4 am-u-md-2 am-text-right">
              企业名称:
            </div>
            <div class="am-u-sm-8 am-u-md-10">
              <input type="text" class="am-input-sm" name="companyname" required>
            </div>
          </div>
        <div class="am-g am-margin-top">
           <div class="am-u-sm-4 am-u-md-2 am-text-right">
             请选择区域:
           </div>
           <div class="am-u-sm-8 am-u-md-10">
           <!--父省级代理start-->
           <switch name="rank">
           <case value="1">
              <select name="province" disabled="disabled">
            <foreach name="sheng" item="data" key='key'>
            <option value="{$key}" >{$data}</option>
           </foreach>
          </select>
          <select name="shi_id" id="selCities" required onchange="javascript:place()">
          <option value="">请选择</option>
            <foreach name="city" item="data" key='key'>
            <option value="{$key}">{$data}</option>
            </foreach>
          </select>
         <select name="area_id" id="selDistricts">
            <option value="0">请选择</option>
            
           
          </select>
          </case>
          <!--省级代理end-->
          <!--父市级代理start-->
          <case value='2'>
            <select name="province" disabled="disabled">
            <foreach name="sheng" item="data" key='key'>
            <option value="{$key}" >{$data}</option>
           </foreach>
          </select>
          <select name="shi_id" id="selCities" disabled="disabled">

            <foreach name="shi" item="data" key='key'>
            <option value="{$key}">{$data}</option>
            </foreach>
          </select>
          <select name="area_id"  required>
          <option value="">请选择</option>
          <foreach name="all" item="data" key='key'>
            <option value="{$key}">{$data}</option>
            </foreach>
          </select>
          </case>
          <!--市级代理end-->
          <default/>
          <!--县级代理start-->
           <select name="province" disabled="disabled">
            <foreach name="sheng" item="data" key='key'>
            <option value="{$key}" >{$data}</option>
           </foreach>
          </select>
          <select name="shi_id" id="selCities" disabled="disabled">
            <foreach name="shi" item="data" key='key'>
            <option value="{$key}">{$data}</option>
            </foreach>
          </select>
          <select name="area_id" id="selDistricts" disabled="disabled">
          <foreach name="area" item="data" key='key' >
            <option value="{$key}">{$data}</option>
            </foreach>
          </select>
          <!--县级代理end-->
          </switch>

           </div>
                   
                    </div>



                     <div class="am-g am-margin-top">
            <div class="am-u-sm-4 am-u-md-2 am-text-right">
            是否为乡镇:
            </div>
          
           &nbsp &nbsp <input type="radio" name="istown"  value="1" />是&nbsp &nbsp
           &nbsp &nbsp  <input type="radio"   name="istown"  value="2" />否
            
          </div> 
            <div class="am-g am-margin-top">
            <div class="am-u-sm-4 am-u-md-2 am-text-right">
              详细地址:
            </div>
            <div class="am-u-sm-8 am-u-md-10">
              <input type="text" class="am-input-sm" name="address"  required><span style="color:red">*街道</span>
            </div>
          </div>
          

         
        
        <div class="am-g am-margin-top">
            <div class="am-u-sm-4 am-u-md-2 am-text-right">
              联系人:
            </div>
            <div class="am-u-sm-8 am-u-md-10">
              <input type="text" class="am-input-sm" name="connectname"  required>
            </div>
            
          </div>

       

         <div class="am-g am-margin-top">
            <div class="am-u-sm-4 am-u-md-2 am-text-right">
              联系人移动电话:
            </div>
            <div class="am-u-sm-8 am-u-md-10">
              <input type="text" class="am-input-sm" name="mobile"  required>
            </div>
            
          </div>
        
        <div class="am-g am-margin-top">
            <div class="am-u-sm-4 am-u-md-2 am-text-right">
              企业座机号:
            </div>
            <div class="am-u-sm-8 am-u-md-10">
              <input type="text" class="am-input-sm" name="telephone"  required>
            </div>
            
          </div>
        


      

      </div>

      <div class="am-tab-panel am-fade" id="tab2">
        
          <div class="am-g am-margin-top">
            <div class="am-u-sm-4 am-u-md-2 am-text-right">
              登录用户名称:
            </div>
            <div class="am-u-sm-8 am-u-md-10">
              <input type="text" class="am-input-sm" name="username" required> 
            </div>
          
          </div>

         

          <div class="am-g am-margin-top">
            <div class="am-u-sm-4 am-u-md-2 am-text-right">
              显示用户名:
            </div>
            <div class="am-u-sm-8 am-u-md-4 am-u-end col-end">
              <input type="text" class="am-input-sm" name="showname">
            </div>
          </div>

         

          <div class="am-g am-margin-top">
            <div class="am-u-sm-4 am-u-md-2 am-text-right">
              用户联系方式:
            </div>
            <div class="am-u-sm-8 am-u-md-10">
              <input type="text" class="am-input-sm" name="umobile">
            </div>
          </div>
          <div class="am-g am-margin-top">
            <div class="am-u-sm-4 am-u-md-2 am-text-right">
              用户邮箱:
            </div>
            <div class="am-u-sm-8 am-u-md-10">
              <input type="text" class="am-input-sm" name="uemail">
            </div>
          </div>
          
          <div class="am-g am-margin-top">
            <div class="am-u-sm-4 am-u-md-2 am-text-right">
              输入密码:
            </div>
            <div class="am-u-sm-8 am-u-md-10">
              <input type="password" class="am-input-sm" name='password' required>
            </div>
          </div>
          <div class="am-g am-margin-top">
            <div class="am-u-sm-4 am-u-md-2 am-text-right" >
              确定密码:
            </div>
            <div class="am-u-sm-8 am-u-md-10">
              <input type="password" class="am-input-sm" name='repass' required>
            </div>
          </div>
          

       
      </div>



    </div>

<div class="am-margin">
    <button type="submit" class="am-btn am-btn-primary am-btn-xs" >提交保存</button>
    <button type="reset" class="am-btn am-btn-primary am-btn-xs">放弃保存</button>
  </div>
  </form>


  </div>

  
</div>
<!-- content end -->


</div>



<footer>
  <hr>
  <p class="am-padding-left">© 2014 AllMobilize, Inc. Licensed under MIT license.</p>
</footer>

<!--[if lt IE 9]>
<script src="http://libs.baidu.com/jquery/1.11.1/jquery.min.js"></script>
<script src="http://cdn.staticfile.org/modernizr/2.8.3/modernizr.js"></script>
<script src="{:C('SUPPLIER_ADMIN_JS')}polyfill/rem.min.js"></script>
<script src="{:C('SUPPLIER_ADMIN_JS')}polyfill/respond.min.js"></script>
<script src="{:C('SUPPLIER_ADMIN_JS')}amazeui.legacy.js"></script>
<![endif]-->

<!--[if (gte IE 9)|!(IE)]><!-->
<script src="{:C('SUPPLIER_ADMIN_JS')}jquery.min.js"></script>
<script src="{:C('SUPPLIER_ADMIN_JS')}amazeui.min.js"></script>
<!--<![endif]-->
<script src="{:C('SUPPLIER_ADMIN_JS')}app.js"></script>
<!-- <script type="text/javascript" src="{:C('SUPPLIER_ADMIN_JS')}jquery.validate.js"></script> -->
<script type="text/javascript" src="{:C('SUPPLIER_ADMIN_JS')}third-party/jquery.min.js"></script>
 <script type="text/javascript" src="{:C('SUPPLIER_ADMIN_JS')}jquery-1.8.3.js"></script> 
<script type="text/javascript" src="{:C('SUPPLIER_ADMIN_JS')}jquery.validate.js"></script>
<script type="text/javascript" src="{:C('SUPPLIER_ADMIN_JS')}messages_zh.js"></script>
<script type="text/javascript" src="http://apps.bdimg.com/libs/jqueryui/1.10.4/jquery-ui.min.js"></script>
<link rel="stylesheet" type="text/css" href="http://apps.bdimg.com/libs/jqueryui/1.10.4/css/jquery-ui.min.css">


<script type="text/javascript">
////区域选择模块
function place(){
  var area=$('#selCities').val();
  jQuery.get('{:U("ShopManage/area")}',
    {region:area,},
    function(data){
      $('#selDistricts').append(data);
    },'text');
}
</script>

<script type="text/javascript">
  $(function(){
       var modultname="Shop";

       $('.'+modultname).addClass('am-in');
});
</script>
</body>
</html>